package com.cloudpolice.door.config;

import com.cloudpolice.door.constant.QueueEnum;
//import myenum.QueueEnum;
import org.springframework.amqp.core.Queue;
import org.springframework.context.annotation.Bean;
import org.springframework.context.annotation.Configuration;


/**
 * RabbitMQ队列配置
 *
 * @author lianghao
 * @create 2019-12-15 9:51
 */
@Configuration
public class RabbitConfig {
 /*   *//**
     * @return 异常队列
     *//*
    @Bean
    public Queue logExceptionQueue() {
        return new Queue(QueueEnum.LOG_QUEUE.getQueueName());
    }

    *//**
     * @return 普通文件队列
     *//*
    @Bean
    public Queue fileExceptionQueue() {
        return new Queue(QueueEnum.FILE_QUEUE.getQueueName());
    }

    @Bean
    public QueueEnum getLogQueueEnum() {
        return QueueEnum.LOG_QUEUE;
    }

    @Bean
    public QueueEnum getFileQueueEnum() {
        return QueueEnum.FILE_QUEUE;
    }
*/

    @Bean
    public Queue doorLogTestQueue() {
        return new Queue("doorLogTest");
    }
    /**
     * @return 静态库人员数据队列
     */
    @Bean
    public Queue staticLibQueue() {
        return new Queue(QueueEnum.STATICLIB_QUEUE.getQueueName());
    }

    /**
     * @return 人脸识别数据队列
     */
    @Bean
    public Queue verifaceQueue() {
        return new Queue(QueueEnum.VERIFACE_QUEUE.getQueueName());
    }

    @Bean
    public QueueEnum getStaticLibQueueEnum(){
        return QueueEnum.STATICLIB_QUEUE;
    }

    @Bean
    public QueueEnum getVerifaceQueueEnum(){
        return QueueEnum.VERIFACE_QUEUE;
    }
}
